-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[feat] Build nav column and header #51
Conversation
6c8b7f8
to
064f6e8
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
omfg it's so amazing ty kyle! i didn't get to go thru all the styles very in depth (i might submit another review shortly) but it's looking great!
- the main thing is to map UserTypeEnum to the actual string we want to display (see my comment)
- destructure StyledComponents props (and make sure they start with $)
components/NavColumn/index.tsx
Outdated
const handleSignOut = () => { | ||
router.push(CONFIG.login); | ||
onClose(); | ||
signOut(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note: we might need to add additional error catching here in the future, but this is great!
export const HamburgerIcon = styled(Icon)` | ||
fill: ${COLORS.shrub}; | ||
`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hm... i think kevin was able to do this before in the Review Onboarding PR - i'll try to link it soon
</defs> | ||
</svg> | ||
), | ||
logo: ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we might consider importing this as a png rather than an svg if the file is large but we can come back to this!
ce26e31
to
6660055
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
additional changes
- check
profileReady
andprofileData
→ if notprofileReady
have a loading style in the bottom half of the nav column - if not profileData, show the Go To Onboarding button
components/Header/index.tsx
Outdated
<HamburgerButton onClick={onNavColumnClick}> | ||
<Icon type="hamburger" /> | ||
</HamburgerButton> | ||
<Link href="/"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this link can also be added to CONFIG!
home: "/",
df551a0
to
314d8f9
Compare
components/Header/index.tsx
Outdated
) | ||
) : ( | ||
// display login link if user is not logged in | ||
<Link href={CONFIG.login}>Login/Sign Up</Link> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe just say Login here, since it's not routing to Signup.
Or, you can create another link with Sign Up.
maybe the gap between the 2 links can be 8px
components/NavColumn/index.tsx
Outdated
<H3 $color={COLORS.shrub} style={{ fontWeight: 300 }}> | ||
Your Account | ||
</H3> | ||
<H4 $color={COLORS.shrub} style={{ fontWeight: 300 }}> | ||
{formatUserType(profileData?.user_type as UserTypeEnum)} | ||
</H4> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your Account should be H4 and User Type should be P3
also let's not use style prop if possible. instead use the $fontWeight prop directly
|
||
return ( | ||
<Container> | ||
<HamburgerButton onClick={onNavColumnClick}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we might want to eventually consolidate all button styles and include them in components/Button.tsx. in this case, we could use a button that basically has no background, outline etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tysm kyle! it's ready to merge!
next steps: consolidate buttons styles, e.g.
- HamburgerButton
- LoginButton/SignUp Button -- they're really the same button, but with diff colors.
- SignOut/Onboarding Button -- they're really the same button, but with diff colors.
font-size: 0.875rem; | ||
`; | ||
|
||
export const OnboardingButton = styled(Link)` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here, eventually we can consolidate the button styles in component/Button.tsx
so that they can be reusable! this big button style is used quite frequently in the app
What's new in this PR 🧑🌾
Description
NavColumn
andHeader
component underNavSystem
Screenshots
Previously:
Most Updated:
Not Logged In
Logged In, Not Onboarded
Logged In, Onboarded
How to review
/onboarding
Next steps
Relevant links
Online sources
Related PRs
CC: @ccatherinetan